/****************************************************************************\
 * @file    Joystick.c
 * @author  马新硕
 * @date    2022/10/12
 * @brief   摇杆和按键的驱动
 * @note    ADC读取摇杆模拟量
 ******************************************************************************
 * @attent  
 ****************************************************************************/

#ifndef _H_JOYSTICK
#define _H_JOYSTICK

#include "stdint.h"

typedef struct{
  int16_t JoyX;
  int16_t JoyY;
  uint8_t ButtonA;
  uint8_t ButtonB;
  uint8_t ButtonC;
  uint8_t ButtonD;
}JoyStick_t;

extern JoyStick_t JoyStick;

void Joystick_Init(void);
void JoyStick_GetData(void);
#endif
